home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Developer CD v2.1
/
Amiga Developer CD v2.1.iso
/
NDK
/
NDK_1.3
/
Autodocs1.3
/
DevicesA-K
/
input.doc
< prev
next >
Wrap
Text File
|
1988-10-16
|
7KB
|
244 lines
TABLE OF CONTENTS
input.device/AddHandler
input.device/RemHandler
input.device/Reset
input.device/SetMPort
input.device/SetMTrig
input.device/SetMType
input.device/SetPeriod
input.device/SetThresh
input.device/Start
input.device/WriteEvent
input.device/AddHandler input.device/AddHandler
NAME
AddHandler - add an input handler to the device
FUNCTION
Add a function to the list of functions called to handle
input events generated by this device. The function is called
as
newInputEvents = Handler(inputEvents, handlerData);
D0 A0 A1
IO REQUEST
io_Message mn_ReplyPort set
io_Device preset by OpenDevice
io_Unit preset by OpenDevice
io_Command IND_ADDHANDLER
io_Data a pointer to an interrupt structure.
is_Data the handlerData pointer described above
is_Code the Handler function address
NOTES
The interrupt structure is kept by the input device until a
RemHandler command is satisfied for it.
input.device/RemHandler input.device/RemHandler
NAME
RemHandler - remove an input handler from the device
FUNCTION
Remove a function previously added to the list of handler
functions.
IO REQUEST
io_Message mn_ReplyPort set
io_Device preset by OpenDevice
io_Unit preset by OpenDevice
io_Command IND_REMHANDLER
io_Data a pointer to the interrupt structure.
NOTES
This command is not immediate
input.device/Reset input.device/Reset
NAME
Reset - reset the input device
FUNCTION
Reset resets the input device without destroying handles
to the open device.
IO REQUEST
io_Message mn_ReplyPort set if quick I/O is not possible
io_Device preset by the call to OpenDevice
io_Unit preset by the call to OpenDevice
io_Command CMD_RESET
io_Flags IOB_QUICK set if quick I/O is possible
input.device/SetMPort input.device/SetMPort
NAME
SetMPort - set the current mouse port
FUNCTION
This command sets the gameport port at which the mouse is
connected.
IO REQUEST
io_Message mn_ReplyPort set if quick I/O is not possible
io_Device preset by the call to OpenDevice
io_Unit preset by the call to OpenDevice
io_Command IND_SETMPORT
io_Flags IOB_QUICK set if quick I/O is possible
io_Length 1
io_Data a pointer to a byte that is either 0 or 1,
indicating that mouse input should be obtained
from either the left or right controller port,
respectively.
input.device/SetMTrig input.device/SetMTrig
NAME
SetMTrig - set the conditions for a mouse port report
FUNCTION
This command sets what conditions must be met by a mouse
before a pending Read request will be satisfied. The trigger
specification is that used by the gameport device.
IO REQUEST
io_Message mn_ReplyPort set if quick I/O is not possible
io_Device preset by the call to OpenDevice
io_Unit preset by the call to OpenDevice
io_Command IND_SETMTRIG
io_Flags IOB_QUICK set if quick I/O is possible
io_Length sizeof(gameportTrigger)
io_Data a structure of type GameportTrigger, which
has the following elements
gpt_Keys -
GPTB_DOWNKEYS set if button down transitions
trigger a report, and GPTB_UPKEYS set if button up
transitions trigger a report
gpt_Timeout -
a time which, if exceeded, triggers a report;
measured in vertical blank units (60/sec)
gpt_XDelta -
a distance in x which, if exceeded, triggers a
report
gpt_YDelta -
a distance in x which, if exceeded, triggers a
report
input.device/SetMType input.device/SetMType
NAME
SetMType - set the current mouse port controller type
FUNCTION
This command sets the type of device at the mouse port, so
the signals at the port may be properly interpreted.
IO REQUEST
io_Message mn_ReplyPort set if quick I/O is not possible
io_Device preset by the call to OpenDevice
io_Unit preset by the call to OpenDevice
io_Command IND_SETMTYPE
io_Flags IOB_QUICK set if quick I/O is possible
io_Length 1
io_Data the address of the byte variable describing
the controller type, as per the equates in
the gameport include file
input.device/SetPeriod input.device/SetPeriod
NAME
SetPeriod - set the key repeat period
FUNCTION
This command sets the period at which a repeating key repeats.
This command always executes immediately.
IO REQUEST - a timerequest
io_Message mn_ReplyPort set if quick I/O is not possible
io_Device preset by the call to OpenDevice
io_Unit preset by the call to OpenDevice
io_Command IND_SETPERIOD
io_Flags IOB_QUICK set if quick I/O is possible
io_tv_Secs the repeat period seconds
io_tv_Micro the repeat period microseconds
input.device/SetThresh input.device/SetThresh
NAME
SetThresh - set the key repeat threshold
FUNCTION
This command sets the time that a key must be held down before
it can repeat. The repeatability of a key may be restricted
(as, for example, are the shift keys).
This command always executes immediately.
IO REQUEST - a timerequest
io_Message mn_ReplyPort set if quick I/O is not possible
io_Device preset by the call to OpenDevice
io_Unit preset by the call to OpenDevice
io_Command IND_SETTHRESH
io_Flags IOB_QUICK set if quick I/O is possible
io_tv_Secs the threshold seconds
io_tv_Micro the threshold microseconds
input.device/Start input.device/Start
NAME
Start - restart after stop
FUNCTION
Start restarts the unit after a stop command.
IO REQUEST
io_Message mn_ReplyPort set if quick I/O is not possible
io_Device preset by the call to OpenDevice
io_Unit preset by the call to OpenDevice
io_Command CMD_START
io_Flags IOB_QUICK set if quick I/O is possible
input.device/WriteEvent input.device/WriteEvent
NAME
WriteEvent - propagate input event(s) to all handlers
FUNCTION
IO REQUEST
io_Message mn_ReplyPort set if quick I/O is not possible
io_Device preset by the call to OpenDevice
io_Unit preset by the call to OpenDevice
io_Command IND_WRITEEVENT
io_Flags IOB_QUICK set if quick I/O is possible
io_Length the size of the io_Data area in bytes: there
are sizeof(inputEvent) bytes per input event.
io_Data a buffer area with input events(s). The
fields of the input event are:
ie_NextEvent
links the events together, the last event
has a zero ie_NextEvent.
ie_Class
ie_SubClass
ie_Code
ie_Qualifier
ie_X, ie_Y
ie_TimeStamp
as desired
NOTES
The contents of the input event(s) are destroyed.